<template>
	<view>
		<view>
			<button class="btn_style" @tap="goLogin()">登入注册页</button>
			<button class="btn_style" @tap="goDetailPage('cityExplore')">城市探索</button>
			<button class="btn_style" @tap="goDetailPage('testTopNewsPage')">自定义置顶新闻组件</button>
			<button class="btn_style" @tap="goDetailPage('testImageApi')">图片接口(选择、预览)</button>
			<button class="btn_style" @tap="goDetailPage('testDownloadFile')">文件下载</button>
			<button class="btn_style" @tap="goDetailPage('IntentPage')">组件传参</button>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				
			}
		},
		methods: {
			goDetailPage(e) {
				if (typeof e === 'string') {
					uni.navigateTo({
						url:'/pages/demos/' + e + '/' +e
					});
				} else {
					uni.navigateTo({
						url:e.url
					});
				}
			},
			
			goLogin() {
				uni.reLaunch({
					url:'/pages/login/login'
				})
			}
		}
	}
</script>

<style>
.btn_style{
	margin: 10rpx;
}
</style>
